home *** CD-ROM | disk | FTP | other *** search
- Path: grimsel.zurich.ibm.com!usenet
- From: wgk@zurich.ibm.com (Keith Whittingham)
- Newsgroups: comp.lang.c++
- Subject: Re: Preprocessor derectives is insufficient for me
- Date: 5 Apr 1996 14:12:05 GMT
- Organization: IBM Research, ZRH
- Message-ID: <4k39nl$lhn@grimsel.zurich.ibm.com>
- References: <ABY08OnW53@npn-price.pskov.su> <DpCEpL.Dtv@mv.mv.com>
- Reply-To: wgk@zurich.ibm.com
- NNTP-Posting-Host: pine.zurich.ibm.com
- X-Newsreader: IBM NewsReader/2 v1.00
-
- In <DpCEpL.Dtv@mv.mv.com>, ENGR@GSSI.MV.COM (Michael Furman) writes:
- >In article <ABY08OnW53@npn-price.pskov.su>, ivl@npn-price.pskov.su says...
- >>
- >>Hello all!
- >>
- >>Just look at this code
- >>
- >>#define DECLARE_CLASS(first_class,second_class,name_class) \
- >>class name_class : virtual public first_class , virtual public second_class
- >
- >>\
- >>{ \
- >>public: \
- >> name_class(); \
- >> ~name_class(); \
- >>public: \
- >> virtual base* operator&(classA&) \
- >> virtual base* operator&(classB&) \
- >
- >You want to generate some C++ code automatically. C/C++ preprocessor
- >was not designed for this kind of work. I would recommend you use some
- >universal macroprocessor or just make your own generator.
- >
- >--
-
- I would go even further and suggest that the stuff in the macro problably
- needs to be in a base class. Time for a design re-evaluation?
-
- Keith
-
-
-